﻿<UserControl
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    x:Class="CoreGallery.Core.UI.AddinItemUserControl"
    MinHeight="80" xmlns:d="http://schemas.microsoft.com/expression/blend/2008" xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" mc:Ignorable="d" d:DesignWidth="469">
    <Border Width="{Binding RelativeSource={RelativeSource FindAncestor, AncestorType={x:Type Selector}}, Path=ActualWidth}" Height="Auto" BorderBrush="#FFA0A0A0" BorderThickness="0,0,0,1" Margin="0,0,0,0" Padding="2,2,2,2">
        <DockPanel x:Name="LayoutRoot" Width="Auto" Height="Auto" Background="#FFFFFFFF" LastChildFill="True">
            <Image DockPanel.Dock="Left" Width="64" Height="64" Source="/CoreGallery.Core;component/images/CoreGallery-logo.gif" x:Name="AddinImage"/>
            <StackPanel Width="Auto" Height="Auto" VerticalAlignment="Stretch" Margin="5,0,10,0">
                <TextBlock Width="Auto" Height="Auto" Text="{Binding AddinName}" TextWrapping="Wrap" Margin="0,0,10,0" FontWeight="Bold" x:Name="AddinNameText"/>
                <TextBlock Width="Auto" Height="Auto" Text="{Binding Version}" TextWrapping="Wrap" x:Name="AddinVersionText"/>
                <TextBlock Text="{Binding Description}" TextWrapping="Wrap" Width="Auto" Margin="0,0,0,5" VerticalAlignment="Center" x:Name="AddinDescriptionText"/>
                <WrapPanel Width="Auto" Height="Auto" VerticalAlignment="Bottom">
                    <Button Width="80" Height="22" Content="Options" x:Name="OptionsButton" Margin="2.5,0,2.5,0" Click="OptionsButton_Click" />
                    <Button Width="80" Height="22" Content="Disable" DockPanel.Dock="Right" Margin="2.5,0,2.5,0" x:Name="DisableButton" Click="DisableButton_Click" />
                    <Button Width="80" Height="22" Content="Remove" DockPanel.Dock="Right" Margin="2.5,0,2.5,0" x:Name="RemoveButton" Click="RemoveButton_Click" />
                </WrapPanel>
            </StackPanel>
        </DockPanel>
    </Border>
</UserControl>
